/**
 * 
 */
package org.vsg.stock.basic.domain.mybatis;

import java.io.Serializable;
import java.util.HashMap;
import java.util.Map;

import org.mybatis.spring.SqlSessionTemplate;
import org.vsg.common.ibatis3.support.SqlSessionTemplateSupport;
import org.vsg.stock.basic.domain.VolCharacterOfFigurePrepared;
import org.vsg.stock.basic.domain.VolFigureKlineDaily;

/**
 * @author Bill Vison
 *
 */
public class VolFigureKlineDailyProxy extends VolFigureKlineDaily 
	implements SqlSessionTemplateSupport{
	
	// ---- defined the dao handle method ----
	private SqlSessionTemplate sqlSessionTemplate ;
	
	public SqlSessionTemplate getSqlSessionTemplate() {
		return sqlSessionTemplate;
	}

	@Override
	public void setSqlSessionTemplate(SqlSessionTemplate sqlSessionTemplate) {
		this.sqlSessionTemplate = sqlSessionTemplate;
	}

	@Override
	public VolCharacterOfFigurePrepared getCharacterPrepared() {
		
		// --- get the proxy ----
		String statment = VolCharacterOfFigurePreparedProxy.class.getName() +"."+
			"findVolCharacterPrepared_volFigureDetailsCode";

		Map<String,Serializable> params = new HashMap<String, Serializable>();
		params.put("volFigureDetailsCode", this.getId().getCodeVolFigureDetails());

		
		VolCharacterOfFigurePrepared object = (VolCharacterOfFigurePrepared)this.sqlSessionTemplate.selectOne(statment , params);

		return object;
	}	


	
}
